#{extends 'main.html' /}
#{set title:'Myprofile' /}


<div class="series_tab">
<div class="series_title">My Profile</div>

<div class="series_follow">
	<img src="@{'/public/images/facebookShareIcon.png'}" width="14" height="14" border="0" style="vertical-align:middle;" />
	<a href="#"  onclick="FacebookInviteFriends();">Invite Your Friends!</a>
</div>

</div>
<div class="clear" style="height:20px"></div>

<div class="search-row">
	<div class="left-search" style="text-decoration: underline;">TV Series</div>	
	<div class="center-search" style="text-decoration: underline;">Rate</div>	
	<div class="right-search" style="text-decoration: underline;">#Followers</div>
	<div class="clear" style="height: 10px;"></div>
</div>


#{if serieList.size() == 0}
<div style="font-size:12px; font-family: verdana;">You don't follow any TV Series!</div>
#{/if}

#{list items:serieList, as:'serie'}
<div class="search-row">
<div class="left-search">
	<a href="/s/${serie.id}"><img src="${serie.poster}" width="15" height="15"></a> &nbsp; 
	<a href="/s/${serie.id}">${serie.name}</a></div>

<div class="center-search">${serie.avgRate}</div>              
<div class="right-search">${serie.numOfFollowers}</div>

</div>
#{/list}

<div class="clear" style="height: 10px;"></div>

<div class="series_menu">
<a href="/myprofile" class="series_menu_a">Topics</a> 
<a href="/myprofile/comments" class="series_menu_a_active">Comments</a> 
<a href="/myprofile/videos" class="series_menu_a">Videos</a> 
</div>

<div class="clear" style="height: 10px;"></div>

<fieldset>
<legend><b>My Comments of Episodes</b></legend>
#{if commentEpisodeList.size() == 0}
There is no Episodes Comment
#{/if}
<div class="comment_list">
	#{list items:commentEpisodeList, as:'comm'}
	<div class="comments">
	
	<div class="show_user_comment">${comm?.episode?.serie?.name}-- Season:${comm?.episode?.season} Episode:${comm?.episode?.episode}:</div>
	
	<div class="show_comment">
	#{if comm.comment.startsWith("<spoiler>") && comm.comment.endsWith("</spoiler>")}
	${comm?.comment.replaceAll("<[^>]*>", "")}
	#{/if}
	
	#{else}
	${comm?.comment}
	#{/else}

	</div>
	
	</div>
	<br />
	#{/list}
	</div>
</fieldset>	
	
<div class="clear" style="height: 10px;"></div>



<fieldset>
<legend><b>My Comments of Series</b></legend>
#{if commentSerieList.size() == 0}
There is no Series Comment
#{/if}
<div class="comment_list">
	#{list items:commentSerieList, as:'comm'}
	<div class="comments">
		
	<div class="show_user_comment">${comm?.serie?.name}:</div>
	
	<div class="show_comment">
	#{if comm.comment.startsWith("<spoiler>") && comm.comment.endsWith("</spoiler>")}
	${comm?.comment.replaceAll("<[^>]*>", "")}
	#{/if}
	
	#{else}
	${comm?.comment}
	#{/else}

	</div>
	
	</div>
	<br />
	#{/list}
	</div>
</fieldset>		
	
<div class="clear" style="height: 10px;"></div>

<fieldset>
<legend><b>My Comments of Topics</b></legend>

#{if commentTopicList.size() == 0}
There is no Topic Comment
#{/if}

<div class="comment_list">
	#{list items:commentTopicList, as:'comm'}
	<div class="comments">
	
	<div class="show_user_comment">${comm?.topic?.topicName}:</div>
	
	<div class="show_comment">
	#{if comm.comment.startsWith("<spoiler>") && comm.comment.endsWith("</spoiler>")}
	${comm?.comment.replaceAll("<[^>]*>", "")}
	#{/if}
	
	#{else}
	${comm?.comment}
	#{/else}

	</div>
	
	</div>
	<br />
	#{/list}
	</div>
</fieldset>	
<div class="clear" style="height: 10px;"></div>

<fieldset>
<legend><b>My Comments of Videos</b></legend>
#{if commentVideoList.size() == 0}
There is no Video Comment
#{/if}
<div class="comment_list">
	#{list items:commentVideoList, as:'comm'}
	<div class="comments">
	
	<div class="show_user_comment">${comm?.video?.serie?.name} [ ${comm?.video?.name} ]:</div>
	
	<div class="show_comment">
	#{if comm.comment.startsWith("<spoiler>") && comm.comment.endsWith("</spoiler>")}
	${comm?.comment.replaceAll("<[^>]*>", "")}
	#{/if}
	
	#{else}
	${comm?.comment}
	#{/else}

	</div>
	
	</div>
	<br />
	#{/list}
	</div>
</fieldset>		
<div class="clear" style="height: 10px;"></div>


